#include<bits/stdc++.h>
using namespace std;
#define int long long
signed main() {
	int t;
	scanf("%lld", &t);
	while (t--) {
		int a, b, c;
		scanf("%lld+%lld=%lld", &a, &b, &c);
		if (a + b == c)
			printf("Right!\n");
		else
			printf("Wrong!\n");
	}
	return 0;
}
